package graph;


import java.awt.*;
import java.awt.image.ImageObserver;

public class Picture extends Drawable {
	private int x1;
	private int y1;
	private int dx;
	private int dy;
	
	private Image img;
	ImageObserver im;

	public Picture(Image image, int leftX1, int topY1, int imageWidth, int imageHeight, ImageObserver imageObserver) {
		super(Color.BLACK);
		this.x1 = leftX1;	
		this.y1 = topY1;
		this.img = image;
		this.im = imageObserver;
		this.dx = imageWidth;
		this.dy = imageHeight;
		
	}

	public void draw(Graphics g) {
		
		
        
        //g.drawImage(img, x1, y1, im); 
        g.drawImage(img,x1,y1,dx,dy,im);
        
        //System.out.println( g.drawImage(img,x1,x2,x1+100,x2+100,im));
		
	}
}
